#ifndef CDEVICE_H
#define CDEVICE_H

#include "CFileSystem.h"
#include "CHardwareFacade.h"
#include "qextserialport-1.2win-alpha/qextserialenumerator.h"

enum
{
    NOTHING_FOUND       = 0,
    MOUSSAVI_DEVICE     = 1,
    ANIBIKE_DEVICE      = 2
};

class CDevice
{
public:
    CDevice(QextPortInfo info, int simulation = 0);
    ~CDevice ( );
    CDevice(const CDevice& device);
    int getDeviceType ( void );
    int isSimulated ( void );
    CFileSystem* getFileSystem ( void );
    CHardwareFacade* getHardwareFacade ( void );
    int CreateFileSystem ( CHardwareParams *params );

    void releaseHardwareFacade ( void );
    void setDeviceNumber (int number);

public:
    CFileSystem      *m_fileSystem;
    CHardwareFacade  *m_hardwareFacade;
    int              m_deviceNumber;

private:
    int               m_simulation;
    int               m_deviceType;
};

#endif // CDEVICE_H
